package cn.huimin.httpClient;

import cn.huimin.httpClient.ex.URLEmptyException;
import org.springframework.web.bind.annotation.RequestMethod;

import java.util.Map;

/**
 * Created by Martin on 2017-2-15.
 */
public interface IHttpClient {

    public RequestMethod getMethodType();

    public String getResponseStatus();

    public void setSocketTimeout(final Integer socketTimeout);

    public void setConnectTimeout(final Integer connectTimeout);

    public void setEncoding(final String encoding);

    public IHttpClient setUrl(final String url);

    public IHttpClient setUrl(final String url, final Long port);

    public void setUri(final String uri);

    public IHttpClient addParam(String name, Object value);

    public IHttpClient addFileParam(String name, String path);

    public IHttpClient addHeader(String name, String value);

    public String sendData() throws URLEmptyException;

    /**
     * 请求参数256加密 惠民256加密
     * @param paramMap
     */
    public void encrypt256Sign(Map<String, String> paramMap);


    /**
     * 请求参数微服务加密
     */
    public void encryptMicroSign() throws URLEmptyException;


}
